/// \file RenderObjectDX9.h
/// \date 2012-12-05
/// \brief concrete class in DX9 that models a render object, as mesh information, etc 

#ifndef _SNAKE_RENDER_RENDEROBJECTDX9_H__
#define _SNAKE_RENDER_RENDEROBJECTDX9_H__

// DX9
#include <d3d9.h>
#include <d3dx9.h>

#include <Render/Include/RenderObject.h>
namespace Render
{

/// \brief concrete class in DX9 that models a render object, as mesh information, etc 
class RenderObjectDX9 : public RenderObject
{
    /// \brief RendererDx9 is the only one that can create, destroy and use this class 
    friend class RendererDX9;

private:
    // ========== INTERNAL METHODS ========== //
    
    /// \brief Constructor, receives the mesh info already created
    RenderObjectDX9(LPD3DXMESH p_mesh, LPD3DXBUFFER p_adjacency_buffer);
    
    /// \brief Destructor, releases the mesh
    virtual ~RenderObjectDX9(void);
    
    /// \brief return DX9Mesh structure pointer
    LPD3DXMESH getLPD3DXMESH();
    
    // ========== ATTRIBUTES ========== //
    
    /// \brief mesh info
    LPD3DXMESH p_mesh;

    /// \brief adjacency buffer info
    LPD3DXBUFFER p_adjacency_buffer;
    
};
};
#endif // _SNAKE_RENDER_RENDEROBJECTDX9_H__
